package com.sc.nft.feign;

import com.sc.nft.dto.AListOfUserExtraPermissionPackagesDTO;
import com.sc.nft.dto.AssignAPermissionPackageToTheUserDTO;
import com.sc.nft.dto.IdRequest;
import com.sc.nft.sup.PageResult;
import com.sc.nft.sup.Result;
import com.sc.nft.vo.AListOfUserExtraPermissionPackagesVO;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.validation.annotation.Validated;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;

@FeignClient(name = "nft-commercial", path = "/commercial/merchantUserExtraPermission")
public interface MerchantUserExtraPermissionClient {

    /**
     * 给用户指定一个权限包
     *
     * @param assignAPermissionPackageToTheUserDTO
     * @return
     */
    @PostMapping(value = "assignAPermissionPackageToTheUser")
    Result assignAPermissionPackageToTheUser(@RequestBody AssignAPermissionPackageToTheUserDTO assignAPermissionPackageToTheUserDTO);

    /**
     * 获取用户额外权限包的列表
     *
     * @param aListOfUserExtraPermissionPackagesDTO
     * @return
     */
    @PostMapping(value = "getsAListOfUserExtraPermissionPackages")
    PageResult<AListOfUserExtraPermissionPackagesVO> getsAllPermissionPackages(@RequestBody AListOfUserExtraPermissionPackagesDTO aListOfUserExtraPermissionPackagesDTO);

    /**
     * 删除用户额外权限包
     *
     * @param idRequest
     * @return
     */
    @PostMapping(value = "removeTheUserPermissionPackage")
    Result removeTheUserPermissionPackage(@RequestBody @Validated IdRequest idRequest);

}
